<%@ include file="../tagHTMLLibIncludes.jsp"%>
<c:url value="${auth}/classDef/${classDefType}/${selectedClassDefId}/viewGeneralPage" var="urlAdd"></c:url>
<c:url value="${auth}/classDef/${classDefType}/${selectedClassDefId}/viewEditGeneralPage" var="urlEdit"></c:url>
<c:url value="${auth}/classInst/${classDefType}/${selectedClassDefId}/viewCreateInst" var="urlCreateInst"></c:url>
<input type="hidden" value="${urlAdd}" id="viewCreateClassDef"/>
<input type="hidden" value="${urlEdit}" id="viewEditClassDef"/>
<input type="hidden" value="${urlCreateInst}" id="viewCreateClassInst"/>
<fieldset class="fieldsCollection">
<legend>${classDef.displayName}</legend>
<div class="dotline"></div>
 <div>
   <div class="buttonURL"><a href="#" id="hrefViewClassDefEditForm"><fmt:message key="menu.modify"/></a></div>
   <div class="buttonURL"><a href="#" id="hrefViewCreateClassDef"><fmt:message key="menu.createChildDef"/></a></div>
   <div class="buttonURL"><a href="#" id="hrefViewCreateClassInst"><fmt:message key="menu.createInst"/></a></div>
</div>
</fieldset>
<display:table name="classInsts" id="classInst" defaultsort="1" pagesize="50" style="width:100%;" class="table">
    <display:column title="">
       <c:if test="${classInst.hasSyncSecurity == false}">
         <img src="images/unsync.png"/>
       </c:if>
    </display:column>
    <display:column title="">${classInst.classDefinition.classDefUID}
        <input type="hidden" value="${auth}/classInst/${classDefType}/${classInst.classDefinition.id}/edit"/>
    </display:column>
    <c:forEach items="${classInst.properties}" var="propertyValue">
    <c:if test="${propertyValue.property.isHidden == false}">
    <c:choose>
        <c:when test="${propertyValue.property.propertyType == 3}">
            <display:column title="${propertyValue.property.displayName}">
            ${fn:formatShortDate(propertyValue.value, sessionScope["OCM.timezoneOffset"])}
            </display:column>
        </c:when>
        <c:otherwise><display:column title="${propertyValue.property.displayName}">${propertyValue.value}</display:column></c:otherwise>
    </c:choose>
    </c:if>
   </c:forEach>
</display:table>
